
Research
Security News
Malicious PyPI Package Exploits Deezer API for Coordinated Music Piracy
Socket researchers uncovered a malicious PyPI package exploiting Deezer’s API to enable coordinated music piracy through API abuse and C2 server control.
filter-array
Advanced tools
Iterates over the elements in an array, returning an array with only the elements for which the callback returns truthy.
Iterates over the elements in an array, returning an array with only the elements for which the callback returns truthy.
npm i filter-array --save
Filter array against given glob patterns, regex or given function.
Params
arr
{Array}: array to filterfilters
{Array|String|Function|RegExp}opts
{Object}: options to pass to micromatchreturns
{Array}Example
var filter = require('filter-array');
filter(['a', 'b', 'c', 'b', 'c', 'e'], function(ele) {
return ele === 'a' || ele === 'b';
});
//=> ['a', 'b', 'b']
For more examples see the tests
Install dev dependencies:
npm i -d && npm test
Pull requests and stars are always welcome. For bugs and feature requests, please create an issue
Jon Schlinkert
Copyright (c) 2014-2015 Jon Schlinkert Released under the MIT license.
This file was generated by verb-cli on May 01, 2015.
FAQs
Iterates over the elements in an array, returning an array with only the elements for which the callback returns truthy.
The npm package filter-array receives a total of 16,270 weekly downloads. As such, filter-array popularity was classified as popular.
We found that filter-array demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncovered a malicious PyPI package exploiting Deezer’s API to enable coordinated music piracy through API abuse and C2 server control.
Research
The Socket Research Team discovered a malicious npm package, '@ton-wallet/create', stealing cryptocurrency wallet keys from developers and users in the TON ecosystem.
Security News
Newly introduced telemetry in devenv 1.4 sparked a backlash over privacy concerns, leading to the removal of its AI-powered feature after strong community pushback.